package com.mvc.service;

import com.mvc.controller.StudentController;
import com.mvc.dao.StudentDAO;
import com.mvc.pojo.Student;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class StudentService {
    @Autowired
    private StudentDAO studentDAO;

    public List<Student> getAllStudent() {
        return studentDAO.getAllStudent();
    }

    public void addStudent(Student student) {
        studentDAO.addStudent(student);
    }
}
